Optimal. Leaf size=23 \[ -\frac {i a}{f (c-i c \tan (e+f x))} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 23, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 29, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {3603, 3568, 32}
\begin {gather*} -\frac {i a}{f (c-i c \tan (e+f x))} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 32
Rule 3568
Rule 3603
Rubi steps
\begin {align*} \int \frac {a+i a \tan (e+f x)}{c-i c \tan (e+f x)} \, dx &=(a c) \int \frac {\sec ^2(e+f x)}{(c-i c \tan (e+f x))^2} \, dx\\ &=\frac {(i a) \text {Subst}\left (\int \frac {1}{(c+x)^2} \, dx,x,-i c \tan (e+f x)\right )}{f}\\ &=-\frac {i a}{f (c-i c \tan (e+f x))}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.14, size = 32, normalized size = 1.39 \begin {gather*} \frac {a (-i \cos (2 (e+f x))+\sin (2 (e+f x)))}{2 c f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.15, size = 20, normalized size = 0.87
method | result | size |
derivativedivides | \(\frac {a}{f c \left (\tan \left (f x +e \right )+i\right )}\) | \(20\) |
default | \(\frac {a}{f c \left (\tan \left (f x +e \right )+i\right )}\) | \(20\) |
risch | \(-\frac {i a \,{\mathrm e}^{2 i \left (f x +e \right )}}{2 c f}\) | \(20\) |
norman | \(\frac {-\frac {i a}{c f}+\frac {a \tan \left (f x +e \right )}{c f}}{1+\tan ^{2}\left (f x +e \right )}\) | \(39\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: RuntimeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 1.05, size = 19, normalized size = 0.83 \begin {gather*} -\frac {i \, a e^{\left (2 i \, f x + 2 i \, e\right )}}{2 \, c f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 37 vs. \(2 (17) = 34\).
time = 0.08, size = 37, normalized size = 1.61 \begin {gather*} \begin {cases} - \frac {i a e^{2 i e} e^{2 i f x}}{2 c f} & \text {for}\: c f \neq 0 \\\frac {a x e^{2 i e}}{c} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.45, size = 33, normalized size = 1.43 \begin {gather*} -\frac {2 \, a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )}{c f {\left (\tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) + i\right )}^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 4.70, size = 19, normalized size = 0.83 \begin {gather*} \frac {a}{c\,f\,\left (\mathrm {tan}\left (e+f\,x\right )+1{}\mathrm {i}\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________